﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="ctlFilterPanel.ascx.cs" Inherits="Ctl_ctlFilterPanel" %>
<%@ Register   Namespace="Grishko.UI"    TagPrefix="uc2" %>
<%@ Register src="ctlFilterEditor.ascx" tagname="ctlFilterEditor" tagprefix="uc1" %>
<script type="text/javascript">
    function OnEnterClick(Target, e) 
    {
        if (event.keyCode == 13) {
            event.cancelBubble = true;
            event.returnValue = false;
            CallServer(Target, '');
        }
    }
        
        
    
</script>

<div class="TblCaption" style ="height :27px" >
    <table width="100%" cellpadding ="2" cellspacing ="0">
        <tr >          
            <td style="width :20px">           
                <asp:ImageButton ID="ImageButton1" ImageUrl ="~/images/grd_plus.gif"  
                    runat="server" onclick="ImageButton1_Click" />                
            </td>                                  
            
            <td style ="width:250px" >
                <asp:DropDownList Width ="95%" ID="cmbFilterlist" runat="server" 
                    AutoPostBack="True" onselectedindexchanged="cmbFilterlist_SelectedIndexChanged">
                </asp:DropDownList>
            </td>
            
            <td style ="width:20px; text-align :center " class ="Split_Left"  >
                <asp:ImageButton ID="btnEdit" ImageUrl ="~/images/icon-edit.gif"  
                    ToolTip ="Редактировать фильтр" runat="server" onclick="btnEdit_Click" />
            </td>
            
            <td  style ="width:20px;text-align :center"  >
                <asp:ImageButton ID="BtnAdd_" ImageUrl ="~/images/add.png" ToolTip ="Добавить фильтр" 
                    runat="server" onclick="BtnAdd_Click" />
            </td >                
            
            <td style ="width:20px; border-right-width:thin; text-align :center">
                <asp:ImageButton ID="btnDel" ImageUrl ="~/images/icon-delete.gif" 
                    ToolTip ="Удалить фильтр" runat="server" onclick="btnDel_Click" />
            </td >
            
            <td class ="Split_Left" style ="width :5px" >
            &nbsp
             </td>   
            
            <td  style ="vertical-align :top"  >                
                
            </td>                       
             <td >
             </td>               
            <td style ="width :250px" >
                <table style ="width :100%" cellpadding ="0" cellspacing ="0" >
                    <tr >
                        <td style ="text-align :right " >
                            &nbsp                            
                        </td> 
                        <td style ="width :5px">
                        </td>                       
                        <td style ="width:20px"  >                        
                            <asp:ImageButton ID="btnFind"  ImageUrl ="~/images/search_button.gif" 
                                runat="server" onclick="btnFind_Click" />
                        </td>
                        <td style ="width :150px" >  
                        
                            <asp:TextBox ID="TxtLexema" Text = <%#(null==_Filter?"": _Filter.Where.Lexeme) %> Width ="97%"  CssClass ="TextBox " runat="server"></asp:TextBox>                                                
                        
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
   </table>
</div> 
<asp:MultiView ID="MultiView1" runat="server">     
     <asp:View ID="View2" runat="server">
        <div id ="FilterList"  class ="EditRowBackGround" style="border-bottom: 1px solid rgb(192, 192, 192);" >
            <uc1:ctlFilterEditor ID="ctlFilterEditor1" runat="server" />
        </div>
     </asp:View>
</asp:MultiView>

